<template>
  <div class="content">
    <div class="top-title">
      <div class="title">{{ title ? title : route.meta.menuName }}</div>
      <div class="back">
        <el-button>返回</el-button>
      </div>
    </div>
    <div class="middle-content">
      <slot></slot>
    </div>
  </div>
</template>

<script setup>
import { ref, onMounted, defineProps } from "vue";
import { useRoute } from "vue-router";
import { useStore } from "../store";
let route = useRoute();
let props = defineProps({
  title: "",
});
</script>

<style lang="less" scoped>
.top-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #eee;
  padding-bottom: 10px;
  margin-bottom: 10px;
  .title {
    font-size: 16px;
    font-weight: bold;
  }
}
</style>
